<jsp:include page="/views/includes/header.jsp" />
<jsp:useBean id="mod" type="Models.Module" scope="request" />

	<h1>Editer <%= mod.getNom() %></h1>
	<form method="POST" action="<%= getServletContext().getContextPath() %>/modules/edit?m=<%= mod.getIdModule() %>">
		<input type="hidden" name="id" value="<%= mod.getIdModule() %>" />
		<div>
			<label for="nom">Nom : </label>
			<input type="text" name="nom" id="nom" value="<%= request.getParameter("nom") != null ? request.getParameter("nom") : "" %>" />
			<% if (request.getAttribute("err-nom") != null) {%>
				<span class="error"><%= request.getAttribute("err-nom") %></span>
			<% } %>
		</div>
		<div>
			<label for="description">Description :</label>
			<input type="text" name="description" id="description" value="<%= request.getParameter("description") != null ? request.getParameter("description") : "" %>" />
			<% if (request.getAttribute("err-desc") != null) { %>
				<span class="error"><%= request.getAttribute("err-desc") %></span>
			<% } %>
		</div>
	</form>
<jsp:include page="/views/includes/footer.jsp" />